#include "FollowMarkerActionGroup.h"
FollowMarkerActionGroup::FollowMarkerActionGroup(ArRobot* robot, int* dir,
		int degree, uint16_t* distance, uint16_t distanceSetPoint,
		 uint16_t dMax, int vMax, int vMin) :
		ArActionGroup(robot) {
	rotate = new RotateAction(dir, degree);
	advance = new AdvanceAction(distance, distanceSetPoint, dMax,  vMax,  vMin);

	addAction(rotate, 50);
	addAction(advance, 50);
}

FollowMarkerActionGroup::~FollowMarkerActionGroup() {
	delete advance;
	delete rotate;
}

void FollowMarkerActionGroup::setDecel(int decel) {
	advance->setDecel(decel);
}

void FollowMarkerActionGroup::setRotVel(int rotVel, int* direction){
	rotate->setRotVel(rotVel,direction);
}


